.container {
    width: 100%;
    min-height: 100vh;
    background: var(--bg-primary);
    color: var(--text-primary);
}

.header {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.back-btn {
    color: var(--text-primary);
    text-decoration: none;
    padding: 8px 16px;
    border: 1px solid var(--border-color);
    border-radius: 20px;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: var(--bg-primary);
    border-color: var(--cyber-blue);
}

.action-btn {
    background: var(--cyber-blue);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.action-btn:hover {
    opacity: 0.9;
}

.main-content {
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.search-bar {
    margin-bottom: 20px;
}

.search-bar input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    background: var(--bg-secondary);
    color: var(--text-primary);
}

.search-bar input:focus {
    outline: none;
    border-color: var(--cyber-blue);
}

.password-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
}

.domain-item {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: 15px;
    padding: 25px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.domain-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--cyber-blue);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.domain-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    border-color: var(--cyber-blue);
}

.domain-item:hover::before {
    opacity: 1;
}

.domain-info {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.domain-url {
    font-size: 1.2em;
    font-weight: 600;
    color: var(--cyber-blue);
    margin-bottom: 5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.domain-url::before {
    content: '🔐';
    font-size: 1.2em;
}

.domain-note {
    color: var(--text-secondary);
    font-size: 0.9em;
    opacity: 0.8;
    text-overflow: ellipsis;
    overflow: hidden;
    white-space: nowrap;
}

.domain-item:hover .domain-note {
    opacity: 1;
}

.domain-meta {
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85em;
    color: var(--text-secondary);
}

.domain-username {
    display: flex;
    align-items: center;
    gap: 5px;
}

.domain-username::before {
    content: '👤';
}

.domain-date {
    opacity: 0.7;
}

@media (max-width: 768px) {
    .password-list {
        grid-template-columns: 1fr;
        padding: 10px;
    }
    
    .domain-item {
        padding: 20px;
    }
}

/* 添加一些动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.domain-item {
    animation: fadeIn 0.3s ease-out forwards;
}

/* 添加骨架屏动画 */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.loading-skeleton {
    background: linear-gradient(90deg, 
        var(--bg-secondary) 25%, 
        var(--border-color) 50%, 
        var(--bg-secondary) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 15px;
    height: 120px;
    margin-bottom: 20px;
}

/* 通用模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    background: var(--bg-primary);
    margin: 50px auto;
    padding: 30px;
    width: 90%;
    max-width: 600px;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    animation: slideIn 0.3s ease-out forwards;
}

.modal h2 {
    margin: 0 0 25px 0;
    color: var(--text-primary);
    font-size: 1.5em;
    font-weight: 600;
}

.close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 24px;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
}

.close:hover {
    color: var(--text-primary);
    transform: scale(1.1);
}

/* 通用表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary);
    font-size: 0.9em;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: var(--bg-secondary);
    color: var(--text-primary);
    font-size: 1em;
    transition: all 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--cyber-blue);
    box-shadow: 0 0 0 2px rgba(0, 120, 255, 0.1);
}

.form-group textarea {
    min-height: 100px;
    resize: vertical;
}

/* 添加密码模态框特定样式 */
#add-password-modal .password-field {
    position: relative;
    display: flex;
    align-items: center;
}

#add-password-modal .password-field input {
    padding-right: 90px;
}

#add-password-modal .password-field button {
    position: absolute;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

#add-password-modal .password-field .toggle-password {
    right: 8px;
}

#add-password-modal .password-field .generate-password {
    right: 45px;
}

#add-password-modal .password-field button:hover {
    color: var(--cyber-blue);
    transform: scale(1.1);
}

#add-password-modal .modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

#add-password-modal .cancel-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}

#add-password-modal .cancel-btn:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
}

#add-password-modal .submit-btn {
    background: var(--cyber-blue);
    border: none;
    color: white;
}

#add-password-modal .submit-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* 查看/编辑密码模态框特定样式 */
#view-password-modal .password-field {
    position: relative;
    display: flex;
    align-items: center;
}

#view-password-modal .password-field input {
    padding-right: 90px;
}

#view-password-modal .password-field button {
    position: absolute;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

#view-password-modal .password-field .toggle-password {
    right: 40px;
}

#view-password-modal .password-field .copy-password {
    right: 8px;
}

#view-password-modal .password-field button:hover {
    color: var(--cyber-blue);
    background: var(--bg-secondary);
}

#view-password-modal .modal-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

#view-password-modal .right-actions {
    display: flex;
    gap: 12px;
}

#view-password-modal .modal-actions button {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.95em;
    cursor: pointer;
    transition: all 0.3s ease;
}

#view-password-modal .delete-btn {
    background: none;
    border: 1px solid var(--error-color);
    color: var(--error-color);
}

#view-password-modal .delete-btn:hover {
    background: var(--error-color);
    color: white;
}

#view-password-modal .cancel-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
}

#view-password-modal .cancel-btn:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
}

#view-password-modal .edit-btn {
    background: var(--cyber-blue);
    border: none;
    color: white;
}

#view-password-modal .edit-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

.icon {
    font-size: 1.1em;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 编辑密码模态框特定样式 */
#edit-password-modal .password-field {
    position: relative;
    display: flex;
    align-items: center;
}

#edit-password-modal .password-field input {
    padding-right: 45px;
}

#edit-password-modal .password-field button {
    position: absolute;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

#edit-password-modal .password-field .toggle-password {
    right: 8px;
}

#edit-password-modal .password-field button:hover {
    color: var(--cyber-blue);
    transform: scale(1.1);
}

#edit-password-modal .modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

#edit-password-modal .cancel-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#edit-password-modal .cancel-btn:hover {
    background: var(--bg-secondary);
    border-color: var(--text-secondary);
}

#edit-password-modal .submit-btn {
    background: var(--cyber-blue);
    border: none;
    color: white;
    padding: 8px 20px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

#edit-password-modal .submit-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

#edit-password-modal input:disabled {
    background: var(--bg-secondary);
    cursor: not-allowed;
    opacity: 0.7;
}

#edit-password-modal .form-group {
    margin-bottom: 20px;
}

#edit-password-modal .form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-secondary);
}

#edit-password-modal .form-group input,
#edit-password-modal .form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--bg-secondary);
    color: var(--text-primary);
}

#edit-password-modal .form-group input:focus,
#edit-password-modal .form-group textarea:focus {
    outline: none;
    border-color: var(--cyber-blue);
    box-shadow: 0 0 0 2px rgba(0, 168, 255, 0.1);
}

#edit-password-modal textarea {
    min-height: 100px;
    resize: vertical;
}

.password-count {
    color: var(--text-secondary);
    font-size: 0.9em;
    padding: 4px 12px;
    background: var(--bg-secondary);
    border-radius: 15px;
    border: 1px solid var(--border-color);
}

.password-count span {
    color: var(--cyber-blue);
    font-weight: bold;
} 